package com.ustudy.entity.ec;

import javax.persistence.Basic;
import javax.persistence.CascadeType;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.FetchType;
import javax.persistence.JoinColumn;
import javax.persistence.Lob;
import javax.persistence.ManyToOne;
import javax.persistence.Table;

import org.ustudy.core.dao.support.entity.LongIdEntity;

/**
 * 商品分类
 * @author Hector.Tong
 * 2017年2月20日 下午2:59:41
 */
@SuppressWarnings("serial")
@Entity(name="GoodsClassify")
@Table(name="EC_GOODS_CLASSIFY")
public class GoodsClassify extends LongIdEntity {
	
	private String code;
	

	private String name;

	@Column
	@Lob
	@Basic(fetch=FetchType.LAZY)
	private String memo;
	
	@ManyToOne(cascade={CascadeType.REFRESH},fetch=FetchType.LAZY)
	@JoinColumn(name="CT_ID")
	private GoodsClassifyType classifyType;
	
	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	}

	public String getCode() {
		return code;
	}

	public void setCode(String code) {
		this.code = code;
	}

	public String getMemo() {
		return memo;
	}

	public void setMemo(String memo) {
		this.memo = memo;
	}

	public GoodsClassifyType getClassifyType() {
		return classifyType;
	}

	public void setClassifyType(GoodsClassifyType classifyType) {
		this.classifyType = classifyType;
	}
	
	
}
